package com.black.app.service.exercise;

import com.black.app.domain.exercise.AppExerciseAction;
import com.baomidou.mybatisplus.extension.service.IService;
import com.black.app.domain.req.exercise.add.AppExerciseActionAddReq;
import com.black.app.domain.req.exercise.edit.AppExerciseActionEditReq;
import com.black.app.domain.req.exercise.query.AppExerciseActionQueryReq;
import com.black.app.domain.resp.exercise.AdminExerciseActionGroupResp;
import com.black.app.domain.resp.exercise.AdminExerciseActionResp;
import com.black.app.domain.resp.exercise.AppExerciseActionResp;
import com.github.pagehelper.PageInfo;

import java.util.Collection;
import java.util.List;

/**
 * @author L
 * @description 针对表【app_exercise_action(锻炼系列的各个视频)】的数据库操作Service
 * @createDate 2024-10-23 16:57:08
 */
public interface AppExerciseActionService extends IService<AppExerciseAction> {

    /**
     * 根据系列id获取对应的锻炼
     *
     * @param sId
     * @return
     */
    AppExerciseActionResp findBySId(Long sId);

    /**
     * 根据id查询
     * @param id
     * @return
     */
    AdminExerciseActionResp findById(Long id);

    /**
     * 分页查询锻炼动作
     * @param req
     * @return
     */
    List<AdminExerciseActionGroupResp> getBySId(AppExerciseActionQueryReq req);

    /**
     * 添加动作
     * @param req
     * @return
     */
    boolean add(AppExerciseActionAddReq req);

    /**
     * 编辑动作
     * @param req
     * @return
     */
    boolean edit(AppExerciseActionEditReq req);

    /**
     * 根据分组id查询动作
     * @param groupId
     * @return
     */
    List<AppExerciseAction> findByGId(Long groupId);
}
